<%--
  Created by IntelliJ IDEA.
  User: zjy
  Date: 2015/4/13
  Time: 16:37
  To change this template use File | Settings | File Templates.
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@include file="/context/mytags.jsp" %>
<t:base type="jquery,easyui,tools"/>
<div class="easyui-layout" fit="true">
    <div region="center" style="padding:1px;">
        <t:datagrid name="studioList" title="" actionUrl="officialController.do?datagrid" idField="articleId" fit="true"
                    queryMode="group">
            <t:dgCol title="articleId" field="articleId" hidden="true"></t:dgCol>
            <t:dgCol title="文章标题" field="title" query="true" width="2"></t:dgCol>
            <t:dgCol title="作者" field="customerEntity.realname" query="true" width="1"></t:dgCol>
            <t:dgCol title="分类标签" field="titleText" width="2"></t:dgCol>
            <t:dgCol title="发布时间" formatter="yyyy-MM-dd hh:mm:ss" field="publishTime" width="1"></t:dgCol>
            <t:dgCol title="审核状态" field="status" dictionary="review" query="true"></t:dgCol>

            <t:dgCol title="操作" field="opt" width="1"></t:dgCol>
            <t:dgFunOpt funname="f_review(articleId)" title="审核"></t:dgFunOpt>
            <t:dgOpenOpt url="officialController.do?articleInfo&id={articleId}" title="查看" width="1000"
                         height="500"></t:dgOpenOpt>

            <%--<t:dgOpenOpt exp="isReview#ne#11" url="studioController.do?review&id={studioId}&type=1" title="查看" width="1000"--%>
            <%--
            <%--&lt;%&ndash;<t:dgDelOpt url="articleController.do?delArticle&id={id}" title="删除"></t:dgDelOpt>&ndash;%&gt;--%>
            <%--&lt;%&ndash;<t:dgToolBar title="新增" icon="icon-add" url="bankController.do?addorupdateView" funname="add"  width="600" height="500"></t:dgToolBar>&ndash;%&gt;--%>
            <%--&lt;%&ndash;<t:dgToolBar title="修改" icon="icon-edit" url="bankController.do?addorupdateView" funname="f_updateBankfInfo"  width="600" height="500"></t:dgToolBar>&ndash;%&gt;--%>
            <%--&lt;%&ndash;<t:dgToolBar title="预览" langArg="common.user" icon="icon-search" url="bankController.do?bankController&id=" funname="f_openPreview"  width="850" height="600"></t:dgToolBar>&ndash;%&gt;--%>
            <%--&lt;%&ndash;<t:dgToolBar title="查看" icon="icon-search" url="sArticleController.do?addorupdate&search=search" funname="detail"  width="800" height="630"></t:dgToolBar>&ndash;%&gt;--%>
        </t:datagrid>
    </div>
</div>
<script type="text/javascript">
    //    //  function f_updateBankfInfo(title, url, id, width, height) {
    //    //    gridname=id;
    //    //    var rowsData = $('#'+id).datagrid('getSelections');
    //    //    if (!rowsData || rowsData.length==0) {
    //    //      tip('请选择编辑项目');
    //    //      return;
    //    //    }
    //    //    if (rowsData.length>1) {
    //    //      tip('请选择一条记录再编辑');
    //    //      return;
    //    //    }
    //    //
    //    //    url += '&id='+rowsData[0].id;
    //    //    createwindow(title, url, width, height);
    //    //  }
    //
    //
    function f_review(articleId) {
        var title = "文章审核";
        var width = 300;
        var height = 100;
        var url = "officialController.do?review&id=" + articleId;
        createwindow(title, url, width, height);
    }


</script>
